package com.fz.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fz.core.BaseEntity;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;

import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.AllArgsConstructor;

/**
 * <p>
 * 商品
 * </p>
 *
 * @author yuelli
 * @since 2024-08-13
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class Goods extends BaseEntity {

    private static final long serialVersionUID = 1L;

    public Goods(Long id, Boolean status) {
        super(id);
        this.status = status;
    }

    public Goods(Long id, String imgs) {
        super(id);
        this.imgs = imgs;
    }

    public Goods(String name, String description, BigDecimal price, Integer store, Long categoryId) {
        this.name = name;
        this.description = description;
        this.price = price;
        this.store = store;
        this.categoryId = categoryId;
    }

    public Goods(Long id, String name, String description, BigDecimal price, Integer store, Long categoryId) {
        super(id);
        this.name = name;
        this.description = description;
        this.price = price;
        this.store = store;
        this.categoryId = categoryId;
    }

    public Goods(String name, String description, BigDecimal price, Integer store, Long categoryId, String imgs, String createTime) {
        this.name = name;
        this.description = description;
        this.price = price;
        this.store = store;
        this.categoryId = categoryId;
        this.imgs = imgs;
        this.createTime = createTime;
    }

    private String name;

    private String description;

    private BigDecimal price;

    private Double discount;

    private Integer store;

    private Integer sales;

    private Long categoryId;

    private String imgs;

    private String createTime;

    private Boolean recommend;

    private Boolean status;

    @TableField(exist = false)
    String[] imagePathList;
}
